This is the dataset reported in the manuscript "Sleep Slow Oscillations and Spindles encode ocular dominance plasticity and promote its consolidation in adult humans" 
 (uploaded on BioRxiv, and available at https://www.biorxiv.org/content/10.1101/2021.03.31.437408v2)

%these files are containing all data for generating the analyses and figures reported in the manuscript. Subject order is the same in every field.


1) dati_SSO_SA.mat contains the variable:

SSO = 

  struct with fields:

           DIbefore: [151 double]  % deprivation index measured before sleep, just after eye patch removal
     Detezioni_ctrl: [15105 double] % sleep slow oscillation detection rate in the control nights (sbj x electrode)
    Detezioni_patch: [15105 double]% sleep slow oscillation detection rate in the MD nights (sbj x electrode
            F_L_105: [5 6 9 10 11 12 13 14 15 16 17 18 19 20 21 26] %indices of left frontal electrodes  for chn128m struct
            F_R_105: [1 2 3 4 7 8 92 98 102 103 104 105] %indices of right frontal electrodes for chn128m struct
              O_105: [62 53 54 58 59 63 64 71] %indices of occipital  electrodes for chn128m struct
           TP_L_105: [22 23 24 25 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 45 46 47 48 49] %indices of left temporo-parietal electrodes  for chn128m struct
           TP_R_105: [43 49 65 66 67 72 73 74 78 79 80 83 84 85 87 88 89 90 91 94 95 96 97 99 100 101] %indices of right temporo-parietal electrodes  for chn128m struct
            chn128m: [1105 struct] structure for electrodes locations on the scalp
        feat_O_ctrl: {105 electrodes 17 feature cell} cell array cointaining all features (*) characterizing SSO in the control nights, each cell with Nsbj values
       feat_O_patch: {10517 cell} cell array cointaining all features (*) characterizing SSO in the MD nights, each cell with Nsbj values
       roi_ctrl_105: [6 24 25 67 91 92 30 43 74] %indices of ensory-motor control ROI electrodes for chn128m struct
        roi_pfr_105: [7 12 13 17 9 8 14] %indices of prefrontal ROI electrodes  for chn128m struct
        
        (*) SSO feature names in labels_sleep within labels_sleep_SA.m
        
        
      2) labels_sleep_SA.mat contains the variable:
   
        labels_sleep =

  117 cell array

    {'amp min'}    {'amp max'}    {'slope1'}    {'slope2'}    {'ZZ time'}    {'NZ time'}    {'NP amp'}    {'NP time'}    {'mod_s'}    {'mod hs'}    {'mod g'}    {'vuoto'}    {'PDS amp'}    {'PDS delay'}    {'BS_s'}    {'BS_hs'}    {'BS_g'}

     
    
    3) dati_spindles_ferr_SA.mat contains the variable:
    
    spindles = 

  struct with fields:

            DIafter: [151 double]  % deprivation index measured after 2h of sleep
           DIbefore: [151 double]  % deprivation index measured before sleep, just after eye patch removal
     Detezioni_ctrl: [15105 double] spindle detection rate in the control nights (sbj x electrode)
    Detezioni_patch: [15105 double] spindle detection rate in the MD nights (sbj x electrode)
            F_L_105: [5 6 9 10 11 12 13 14 15 16 17 18 19 20 21 26]
            F_R_105: [1 2 3 4 7 8 92 98 102 103 104 105]
              O_105: [52 53 54 57 58 59 62 63 64 70 71 77]
           TP_L_105: [22 23 24 25 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 45 46 47 48 49]
           TP_R_105: [43 49 65 66 67 72 73 74 78 79 80 83 84 85 87 88 89 90 91 94 95 96 97 99 100 101]
            chn128m: [1105 struct]
        feat_O_ctrl: {1052 cell} cell array cointaining all features (*) characterizing spindles in the control nights, each cell with Nsbj values
       feat_O_patch: {1052 cell} cell array cointaining all features (*) characterizing spindles in the control nights, each cell with Nsbj values
        
      
       
       4) bandsPower_SA.mat  contains the variables:
      
       band_labels =    {'SWA'}    {'Hdelta'}    {'teta'}    {'alfa'}    {'sigma'}    {'beta'}    {'gamma'}
    

        TABdb (30x105x7)  30 sbj alternating between control and MD night data, 105 channels, 7 bands   

4) MDmorn_EEG_powerbands.mat

  P_alfa               15x8x95         % for each electrode, power estimate in the alpha band              
  P_beta               15x8x95         % for each electrode, power estimate in the beta band              
  P_beta1              15x8x95         % for each electrode, power estimate in the beta1 band
  P_beta2              15x8x95         % for each electrode, power estimate in the beta2 band
  P_delta              15x8x95         % for each electrode,power estimate in the delta band
  P_gamma              15x8x95         % for each electrode, power estimate in the gamma band
  P_teta               15x8x95         % for each electrode, power estimate in the theta band
  chanlocs              1x95           % structure for electrodes locations on the scalp              
  psicometriche        15x5            % columns 3 and 4 cointain individual DI before and after dark exposure  